﻿using UnityEngine;
using System.Collections;

public class HealthDamage : MonoBehaviour {
	private int changeHealth = 50;
	//Change amount of health taken away after test

	void OnTriggerEnter2D(Collider2D other){
		if (other.tag == "Player") {
			StartUpScripts.PlayerHealth = StartUpScripts.PlayerHealth - changeHealth;
			Debug.Log (StartUpScripts.PlayerHealth);
			Destroy (gameObject);
		}
	}
}
